import request from '@/utils/request'

// 查询螺列表
export function listSnail(query) {
  return request({
    url: '/warehouse/snail/list',
    method: 'get',
    params: query
  })
}

// 查询螺详细
export function getSnail(snailCode) {
  return request({
    url: '/warehouse/snail/' + snailCode,
    method: 'get'
  })
}

// 新增螺
export function addSnail(data) {
  return request({
    url: '/warehouse/snail',
    method: 'post',
    data: data
  })
}

// 修改螺
export function updateSnail(data) {
  return request({
    url: '/warehouse/snail',
    method: 'put',
    data: data
  })
}

// 删除螺
export function delSnail(snailCode) {
  return request({
    url: '/warehouse/snail/' + snailCode,
    method: 'delete'
  })
}

// 导出螺
export function exportSnail(query) {
  return request({
    url: '/warehouse/snail/export',
    method: 'get',
    params: query
  })
}